<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Title</title>
</head>
<body>
<script>
  let str = "werwrwr113fffff23456gyfh67579";

  function getNumber(str) {
    let arr = [];
    let tem = '';
    for (let i = 0; i < str.length; i++) {
      if (str.charAt(i) <= '9' && str.charAt(i) >= 0) {
        tem += str.charAt(i);
      } else {
        if (tem) {
          arr.push(tem);
          tem = ''
        }
      }
    }
    if(tem) arr.push(tem);
    return arr
  }

  console.log(getNumber(str));
</script>
</body>
</html>